<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org" lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title th:text="${title}">支付成功</title>
    <link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.1.3/css/bootstrap.min.css" rel="stylesheet">
    <style>
        .payment-success-container {
            max-width: 800px;
            margin: 50px auto;
            padding: 20px;
            background: #fff;
            border-radius: 8px;
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
            text-align: center;
        }
        .section-title {
            font-size: 24px;
            font-weight: bold;
            margin-bottom: 20px;
            color: #333;
        }
        .order-info {
            font-size: 18px;
            color: #555;
            margin-bottom: 15px;
        }
        .price-tag {
            color: #ff5722;
            font-weight: bold;
            font-size: 20px;
        }
        .btn-return {
            width: 100%;
            padding: 10px;
            font-size: 16px;
            background-color: #ff5722;
            border: none;
            color: white;
            border-radius: 8px;
            cursor: pointer;
            margin-top: 20px;
        }
        .btn-return:hover {
            background-color: #e64a19;
        }
    </style>
</head>
<body>
<!-- 引入头部 -->
<div th:replace="fragments/header :: header(title='支付成功')"></div>

<!-- 支付成功页面内容 -->
<div class="payment-success-container">
    <div class="section-title">支付成功</div>
    <div class="order-info">订单号：<span th:text="${session.currentOrder.orderNo}">123456789</span></div>
    <div class="order-info">支付金额：<span class="price-tag" th:text="'¥' + ${#numbers.formatDecimal(session.currentOrder.totalAmount, 1, 2)}">¥00.00</span></div>
    <div class="order-info">支付时间：<span th:text="${session.currentOrder.paymentTime}">2023-10-01 12:00:00</span></div>
    <button class="btn-return" onclick="window.location.href='/restaurant/all'">返回首页</button>
</div>

<!-- 引入 Bootstrap JS -->
<script src="https://cdn.bootcdn.net/ajax/libs/bootstrap/5.1.3/js/bootstrap.bundle.min.js"></script>
</body>
</html>